package com.imooc.springcloud;

import org.springframework.boot.WebApplicationType;
import org.springframework.boot.autoconfigure.SpringBootApplication;
import org.springframework.boot.builder.SpringApplicationBuilder;
import org.springframework.cloud.client.discovery.EnableDiscoveryClient;

/**
 * @author caryguan
 * @version V1.0
 * @Package com.imoo.springcloud
 * @date 2020/10/19 16:06
 */

@SpringBootApplication
@EnableDiscoveryClient//消费方和提供方其实注解和启动方式是一样的,第一次我写成了enableEurekaClient报错
// @EnableFeignClients//定义feign组件 client并不需要调用feign,feign是消费者端的调用
public class FeignClientApplication {


    public static void main(String[] args) {
        new SpringApplicationBuilder(FeignClientApplication.class).web(WebApplicationType.SERVLET).run(args);
    }
}